/*
 * $Id: CfgTaskType.java,v 1.14 2009/11/04 05:05:49 navdeep_mahajan Exp $
 *
 * Copyright (C) 2006 General Electric Company. All Rights Reserved.
 *
 * This software is the confidential and proprietary information of the General
 * Electric Company (GE). You shall not disclose this software and shall use it
 * only in accordance with the terms of the license agreement you entered into
 * with GE.
 *
 * GE MAKES NO REPRESENTATIONS OR WARRANTIES ABOUT THE SUITABILITY OF THE
 * SOFTWARE, EITHER EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE IMPLIED
 * WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE, OR
 * NON-INFRINGEMENT. GE SHALL NOT BE LIABLE FOR ANY DAMAGES SUFFERED BY LICENSEE
 * AS A RESULT OF USING, MODIFYING, OR DISTRIBUTING THIS SOFTWARE OR ITS
 * DERIVATIVES.
 */

package com.ge.healthcare.autosc.common.database.pojo;

import java.io.Serializable;


public class CfgTaskType extends AbstractCfgTaskType implements Serializable {

	/**
	 * Eclipse generated
	 */
	private static final long serialVersionUID = 2769670676065806989L;
	//Hibernate Variables
	public static final String TABLE_NAME = "com.ge.healthcare.autosc.common.database.pojo.CfgTaskType";
	public static final String COL_ID = "taskTypeId";
	public static final String COL_NAME = "taskTypeName";
	public static final Object COL_TASK_CATEGORY_ID = "taskCategoryId";
	
	public static final Character ALWAYS_RUN_CODE = 'D';
	public static final Character SUCESS_CODE = 'S';
	public static final Character FAILED_CODE = 'F';

	public static final Character INTERNAL_AUTOSC = 'F';
	public static final Character EXTERNAL_AUTOSC = 'T';

	public boolean equals(CfgTaskType taskType) {
		if (this.getTaskTypeId().equals(taskType.getTaskTypeId())
				&& this.getTaskTypeName().equals(taskType.getTaskTypeName())) {
			return true;
		}
		return false;
	}

	public String toString() {
		StringBuffer str = new StringBuffer();
		str = str.append("{taskTypeId=").append(this.getTaskTypeId()).append(
				"},");

		str = str.append("{taskTypeName=").append(this.getTaskTypeName())
				.append("},");
		str = str.append("{taskCategoryId=").append(this.getTaskCategoryId())
		.append("},");
		str = str.append("{maxRetryCount=").append(this.getMaxRetryCount())
				.append("},");
		str = str.append("{codeGroup=").append(this.getCodeGroup())
				.append("},");
		str = str.append("{extAutosc=").append(this.getExtAutosc())
				.append("},");
		str = str.append("{Priority=").append(this.getPriority())
		.append("},");
		str = str.append("{RunTime Length=").append(this.getRuntimeLength())
		.append("},");
		str = str.append("{Retry Delay=").append(this.getRetryDelay())
		.append("}");
		return str.toString();
	}
}
